from django.contrib import admin
from webapp.models import *
# Register your models here.

class HostAdmin(admin.ModelAdmin):
    prepopulated_fields = {"hostname": ("hostname",)}
    list_display = ('hostname', 'ip', 'port')
    search_fields = ('hostname', 'ip')
    ordering = ('-mod_date',)
    date_hierarchy = 'mod_date'

admin.site.register(Tag)
admin.site.register(Host,HostAdmin)
admin.site.register(GroupVar)